<template>
  <el-link class="el_link" :underline="false" :type="type" v-if="hasPermission()">
    <slot />
  </el-link>
</template>
<script>
export default {
  name: "AuthLink",
  props: {
    uid: {
      type: [String, Number],
      default: "",
    },
    type: {
      type: [String, Number],
      default: "default",
    },
    link: {
      type: Boolean,
      default: false,
    },
  },
  data() {
    return {};
  },
  mounted() {
  },
  methods: {
    // 判断是否有权限
    hasPermission() {
      // let id = this.uid;
      // let list = this.$store.state.currentPermission;
      // let idx = list.findIndex((k) => k.id == id);
      // if (idx < 0) {
      //   return false;
      // } else {
      //   return true;
      // }
    },
  },
};
</script>
<style lang="scss" scoped>
.el_link:hover {
  text-decoration: none;
}
</style>